package com.xinxin.socket.handler;

import com.xinxin.socket.msg.NetMsg;
import io.netty.channel.ChannelHandlerContext;
import lombok.extern.slf4j.Slf4j;

/**
 * @author ys
 * @date 2020/8/7
 */
@Slf4j
public class DefaultNetMsgHandler extends NetMsgHandler {

    @Override
    protected void channelRead0(ChannelHandlerContext ctx, NetMsg netMsg) {
        netMsg.release();
        log.info("NetMsg released, refCnt: {}", netMsg.refCnt());
    }
}
